package com.ry.servcie;

import com.ry.pojo.Banner;
import com.ry.pojo.IndexItems;
import org.springframework.stereotype.Service;

import java.util.ArrayList;
import java.util.List;

@Service
public class TestindexitemsImpl implements Testindexitems {
    @Override
    public List<IndexItems> getItems() {
        List<IndexItems> list = new ArrayList<>();
        list.add(new IndexItems(1l,"name1","/images/banner.jpg",100));
        list.add(new IndexItems(2l,"name2","/images/banner.jpg",200));
        list.add(new IndexItems(3l,"name3","/images/banner.jpg",300));
        list.add(new IndexItems(4l,"name4","/images/banner.jpg",400));
        list.add(new IndexItems(5l,"name5","/images/banner.jpg",500));
        list.add(new IndexItems(6l,"name6","/images/banner.jpg",600));
        list.add(new IndexItems(7l,"name7","/images/banner.jpg",700));
        list.add(new IndexItems(8l,"name8","/images/banner.jpg",800));
        return list;
    }

    @Override
    public List<Banner> getbanner() {
        List<Banner> banners = new ArrayList<>();
        banners.add(new Banner(1000l,"/images/banner.jpg"));
        banners.add(new Banner(2000l,"/images/banner.jpg"));
        banners.add(new Banner(3000l,"/images/banner.jpg"));
        banners.add(new Banner(4000l,"/images/banner.jpg"));
        return banners;
    }
}
